<style type="text/css">
    .class-left {
        margin-left: 50px;
        margin-right: 0 !important;
    }

    #form-calss .layui-input-inline, #form-calss .layui-input-block {
        width: 240px;
    }

    #form-calss .layui-inline {
        margin-bottom: -10px;
        margin-right: 0px;
    }

    #form-calss .layui-textarea {
        min-height: 55px;
    }
</style>
<div style="margin: 10px;padding: 10px;border: 2px solid #eee;position: relative;">
    <form class="layui-form layui-form-pane" action="#" id="form-calss">
        <div class="layui-form-item">
            <div class="layui-inline" style="display:inline-flex">
                <label class="layui-form-label">租金</label>
                <div class="layui-input-block" style="width: 139px; margin: 0px;    left: 0px;">
                    <input type="text" name="rent" id="date1" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
                <div class="layui-inline" style="width: 100px">
                    <select name="rentUnit" lay-verify="required">
                        <option value="元/月">元/月</option>
                        <option value="元/m²">元/m²</option>
                        <option value="元/m²/天">元/m²/天</option>
                        <option value="元/m².月">元/m².月</option>
                        <option value="万元">万元</option>
                    </select>
                </div>
            </div>
            <div class="layui-inline class-left">
                <label class="layui-form-label">售价</label>
                <div class="layui-input-inline" style="width: 139px; margin: 0px;">
                    <input type="text" name="sell" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
                <div class="layui-inline" style="width: 100px">
                    <select name="sellUnit" lay-verify="required">
                        <option value="元/m²">元/m²</option>
                        <option value="万元">万元</option>
                    </select>
                </div>
            </div>
        </div>
        <div class="layui-form-item ">
            <div class="layui-inline">
                <label class="layui-form-label">建筑面积</label>
                <div class="layui-input-block">
                    <input type="text" name="area" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
            </div>
            <div class="layui-inline class-left">
                <label class="layui-form-label">竣工时间</label>
                <div class="layui-input-inline">
                    <input class="layui-input" id="dateTime" name="completedTime" lay-verify="required" placeholder="yyyy-MM-dd" readonly type="text">
                </div>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">物业公司</label>
                <div class="layui-input-block">
                    <input type="text" name="property" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
            </div>
            <div class="layui-inline class-left">
                <label class="layui-form-label">物业费</label>
                <div class="layui-input-inline" style="width: 139px; margin: 0px;">
                    <input type="text" name="propertyFee" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
                <div class="layui-inline" style="width: 100px">
                    <select name="propertyFeeUnit" lay-verify="required">
                        <option value="元/月">元/月</option>
                        <option value="元/m²/天">元/m²/天</option>
                        <option value="元/m².月">元/m².月</option>
                    </select>
                </div>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">车位数量</label>
                <div class="layui-input-block">
                    <input type="text" name="carportNum" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
            </div>
            <div class="layui-inline class-left">
                <label class="layui-form-label">车位租金</label>
                <div class="layui-input-inline" style="width: 139px; margin: 0px;">
                    <input type="text" name="carportRent" lay-verify="required" autocomplete="off" class="layui-input">
                </div>
                <div class="layui-inline" style="width: 100px">
                    <select name="carportRentUnit" lay-verify="required">
                        <option value="元/m²/天">元/天</option>
                        <option value="元/月">元/月</option>
                        <option value="元/m².月">元/小时</option>
                    </select>
                </div>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">电梯</label>
                <div class="layui-input-block">
                    <input type="text" name="elevator" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
            </div>
            <div class="layui-inline class-left">
                <label class="layui-form-label">网络</label>
                <div class="layui-input-inline">
                    <input type="text" name="network" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">开发商</label>
                <div class="layui-input-block">
                    <input type="text" name="developer" id="developer" autocomplete="off" lay-verify="required" class="layui-input">
                </div>
            </div>
            <div class="layui-inline class-left">
                <label class="layui-form-label">总楼层</label>
                <div class="layui-input-inline">
                    <input type="text" name="reserve" id="reserve" autocomplete="off" class="layui-input">
                </div>
            </div>
        </div>

        <div class="layui-form-item layui-form-text" style="width: 99%">
            <label class="layui-form-label">入住企业</label>
            <div class="layui-input-block" style="width: 100%">
                <textarea placeholder="" name="entrepreneur" lay-verify="required" class="layui-textarea" maxlength="300"></textarea>
            </div>
        </div>
        <div class="layui-form-item layui-form-text" style="width: 99%">
            <label class="layui-form-label">楼盘简介</label>
            <div class="layui-input-block" style="width: 100%">
                <textarea placeholder="" name="description" lay-verify="required" class="layui-textarea" maxlength="2000"></textarea>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-input-block">
                <button class="layui-btn" lay-submit lay-filter="form-attr-submint">立即更改</button>
            </div>
        </div>
        <input id="from-build-id" name="build_id" value="" type="hidden">
    </form>

</div>

<script type="text/javascript">
    layui.use(['form', 'laydate'], function (obj) {
        var form = layui.form, laydate = layui.laydate;
        laydate.render({elem: '#dateTime'});
        form.render();
        form.on('submit(form-attr-submint)', function (data) {
            $.post("/officeBuilding/building/updataAttr.do", data.field, function (result, status) {
                if (result.data == true) {
                    layer.msg('更新成功!', {icon: 0});
                } else if(result.data == false) {
                    layer.msg('更新失败!', {icon: 2});
                }
            }, "json");
            return false;
        })

    });

</script>